From: Florian Müllner Date: Fri, 15 Jun 2012 13:52:47 +0000 (+0200) Subject: workspace: Minor cleanup X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~6460 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=0804cefbeed8ce708aa163dbdf3e50b07bcabe48;p=gnome-shell.git workspace: Minor cleanup _hideAllOverlays() has only been used in a single place for quite some time now, so move its code into the caller and save a loop. https://bugzilla.gnome.org/show_bug.cgi?id=678416 --- diff --git a/js/ui/workspace.js b/js/ui/workspace.js index 25626fc5e..e00a86c0b 100644 --- a/js/ui/workspace.js +++ b/js/ui/workspace.js @@ -1121,15 +1121,6 @@ const Workspace = new Lang.Class({ } }, - _hideAllOverlays: function() { - for (let i = 0; i < this._windows.length; i++) { - let clone = this._windows[i]; - let overlay = this._windowOverlays[i]; - if (overlay) - overlay.hide(); - } - }, - _delayedWindowRepositioning: function() { if (this._windowIsZooming) return true; @@ -1329,6 +1320,10 @@ const Workspace = new Lang.Class({ // Position and scale the windows. for (let i = 0; i < this._windows.length; i++) { let clone = this._windows[i]; + let overlay = this._windowOverlays[i]; + + if (overlay) + overlay.hide(); clone.zoomFromOverview(); @@ -1353,8 +1348,6 @@ const Workspace = new Lang.Class({ }); } } - - this._hideAllOverlays(); }, destroy : function() {